API Documentation
Public Member Functions | Public Attributes | List of all members
nkAstraeus::ArrayData< T > Struct Template Reference

Holds array data, with ownership. More...

Inheritance diagram for nkAstraeus::ArrayData< T >:
nkAstraeus::ArrayView< T >

Public Member Functions

virtual ~ArrayData ()
 
ArrayView< T > * subView (size_t offset, size_t size)
 

Public Attributes

T * _ptr = nullptr
 The data pointer.
 
size_t _size = 0
 The size of the data held.
 

Detailed Description

template<typename T>
struct nkAstraeus::ArrayData< T >

Holds array data, with ownership.

Constructor & Destructor Documentation

◆ ~ArrayData()

template<typename T >
virtual nkAstraeus::ArrayData< T >::~ArrayData ( )
virtual

Destructor.

Member Function Documentation

◆ subView()

template<typename T >
ArrayView<T>* nkAstraeus::ArrayData< T >::subView ( size_t  offset,
size_t  size 
)

Allows to retrieve a view over the data, with a given offset and size. A view doesn't own the data, the ArrayData remains the owner.

Parameters
offsetThe offset, in the data, from where the view should start.
sizeThe size the view should have.
Returns
A view over the data requested.

The documentation for this struct was generated from the following file: